<?php

namespace App\Http\Controllers\Admin;

use Illuminate\Http\Request;

use App\Http\Requests;
use App\Http\Controllers\Controller;

class IndexController extends Controller
{
    /**
     * Display a listing of the resource.
     *
     * @return \Illuminate\Http\Response
     */
    public function index()
    {
        //
        // dd(session('user'));
        return view('admin.index.index');
    }

    // 退出登录
    public function logout()
    {
        
        session(['user'=>null]);    
        // 跳转到登录页面
        return redirect('admin/login');

    }


}
